<include file="public+header" />

	
	<div class="title"><lang package='dataindex'>数据调用列表</lang> ( <a href="{:G::U( 'dataindex/option' )}" title="<lang package='dataindex'>数据调用配置</lang>" ><lang package='dataindex'>数据设置</lang></a> | <a href="{:G::U( 'dataindex/clear' )}" title="<lang package='dataindex'>清空所有数据调用记录</lang>" class="button button-red"><lang package='dataindex'>清空</lang></a> )</div>

	
	<div class="toolbar">
		
		<div class="operate left" >
			<input type="button" name="update" value="<lang package='dataindex'>更新缓存</lang>" onclick="updateDatacache()" class="update button">
			<input type="button" name="add" value="<lang>新增</lang>" onclick="add()" class="add button">
			<input type="button" name="edit" value="<lang>编辑</lang>" onclick="edit()" class="edit button">
			<input type="button" name="delete" value="<lang>删除</lang>" onclick="foreverdel()" class="delete button">
		</div>
		
		<div class="right search_form">
		<form method='get' action="{:G::U( 'dataindex/index' )}">
			<div class="left">
				<input type="hidden" name="c" value="{:MODULE_NAME}"/>
				<input type="hidden" name="a" value="{:ACTION_NAME}"/>
				<input type="text" name="dataindex_ids" title="<lang package='dataindex'>数据结果记录</lang>" class="field" >
				<input type="submit" id="" value="<lang>查询</lang>" onclick="" class="search button">
			</div>
		</form>
	</div>
	</div>

	
	<span class="clear"></span>

	
	<div id="content" class="content">
		<table class="data full" id="checkList">
		<thead>
		<tr>
			<th><input type="checkbox" onclick="checkAll('checkList')"></th>
			<th><a href="javascript:sortBy('dataindex_id','{$sSortByUrl}')" {if G+getGpc('order_','G')=='dataindex_id' && G+getGpc('sort_','G')=='asc'}class="order_desc"{/if}{if G+getGpc('order_','G')=='dataindex_id' && G+getGpc('sort_','G')=='desc'}class="order_asc"{/if} title="<lang package='dataindex'>按照编号</lang>{$sSortByDescription}<lang>排列</lang> "><lang package='dataindex'>编号</lang></a></th>
			<th><a href="javascript:sortBy('dataindex_md5hash','{$sSortByUrl}')" {if G+getGpc('order_','G')=='dataindex_md5hash' && G+getGpc('sort_','G')=='asc'}class="order_desc"{/if}{if G+getGpc('order_','G')=='dataindex_md5hash' && G+getGpc('sort_','G')=='desc'}class="order_asc"{/if} title="<lang package='dataindex'>按照hash值</lang>{$sSortByDescription}<lang>排列</lang> "><lang package='dataindex'>唯一hash值</lang></a></th>
			<th><a href="javascript:sortBy('create_dateline','{$sSortByUrl}')" {if G+getGpc('order_','G')=='create_dateline' && G+getGpc('sort_','G')=='asc'}class="order_desc"{/if}{if G+getGpc('order_','G')=='create_dateline' && G+getGpc('sort_','G')=='desc'}class="order_asc"{/if} title="<lang package='dataindex'>按照创建时间</lang>{$sSortByDescription}<lang>排列</lang> "><lang package='dataindex'>创建时间</lang></a></th>
			<th><a href="javascript:sortBy('update_dateline','{$sSortByUrl}')" {if G+getGpc('order_','G')=='update_dateline' && G+getGpc('sort_','G')=='asc'}class="order_desc"{/if}{if G+getGpc('order_','G')=='update_dateline' && G+getGpc('sort_','G')=='desc'}class="order_asc"{/if} title="<lang package='dataindex'>按照更新时间</lang>{$sSortByDescription}<lang>排列</lang> "><lang package='dataindex'>更新时间</lang></a></th>
			<th><a href="javascript:sortBy('dataindex_totals','{$sSortByUrl}')" {if G+getGpc('order_','G')=='dataindex_totals' && G+getGpc('sort_','G')=='asc'}class="order_desc"{/if}{if G+getGpc('order_','G')=='dataindex_totals' && G+getGpc('sort_','G')=='desc'}class="order_asc"{/if} title="<lang package='dataindex'>按照数据结果数</lang>{$sSortByDescription}<lang>排列</lang> "><lang package='dataindex'>数据结果</lang></a></th>
			<th><lang>操作</lang></th>
			</tr>
			</thead>
			<tbody>
			<foreach for=oList>
			<tr>
			<td><input type="checkbox" name="key" value="{$value:dataindex_id}"></td>
			<td>{$value:dataindex_id}</td>
			<td>{$value:dataindex_md5hash}
			{~$arrDatastrings=E::mbUnserialize($value['dataindex_datastring'])}
			<div style="background:#FFF;padding:5px;border:1px dashed #ccc;">
			Where:{~print_r($arrDatastrings['where'])}<br/>
			Order:{$arrDatastrings['order']}<br/>
			Limit:{$arrDatastrings['limit'][0]}-{$arrDatastrings['limit'][1]}
			</div>
			</td>
			<td>{$value:create_dateline|date='Y-m-d',**}
			<div class="row-actions">
				<span class='edit'><a href="javascript:updateDatacache('{$value:dataindex_id}')" title="<lang package='dataindex'>缓存</lang> 《{$value:dataindex_md5hash}》"><lang package='dataindex'>缓存</lang></a>|</span>
				<span class='edit'><a href="javascript:edit('{$value:dataindex_id}')" title="<lang>编辑</lang> 《{$value:dataindex_md5hash}》"><lang>编辑</lang></a>|</span>
				<span class='delete'><a href="javascript:foreverdel('{$value:dataindex_id}');" title="<lang>删除</lang>"><lang>删除</lang></a></span>
			</div></td>
			<td>{if $value['update_dateline']}{$value:update_dateline|date='Y-m-d',**}{d*else}Never{/if}</td>
			<td>{$value:dataindex_totals}</td>
			<td>{if $value['dataindex_auto']==1}&nbsp;{d*else}<a href="javascript:edit('{$value:dataindex_id}')"><lang>编辑</lang></a>{/if}</td>
			</tr>
			</foreach>
		</tbody>
		</table>

		
		<div class="toolbar">
			
			<div class="operate" >
				<input type="button" name="update" value="<lang package='dataindex'>更新缓存</lang>" onclick="updateDatacache()" class="update button">
				<input type="button" name="add" value="<lang>新增</lang>" onclick="add()" class="add button">
				<input type="button" name="edit" value="<lang>编辑</lang>" onclick="edit()" class="edit button">
				<input type="button" name="delete" value="<lang>删除</lang>" onclick="foreverdel()" class="delete button">
			</div>
		</div>

		
		{$sPageNavbar}

	</div>
	

<include file="public+footer">